home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / rexx / 2012 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  1.6 KB

  1. Path: STERLING.COM!Ross_Patterson
  2. Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU
  3. Newsgroups: comp.lang.rexx
  4. Message-ID: <199604161210.IAA16964@mail.Reston.VMD.Sterling.COM>
  5. Date: Tue, 16 Apr 1996 08:50:59 EDT
  6. Sender: REXX Programming discussion list <REXXLIST@UGA.CC.UGA.EDU>
  7. From: Ross Patterson <Ross_Patterson@STERLING.COM>
  8. Subject: Re: Date arithmetic missing in REXX
  9.  
  10. javier5@IBM.NET writes:
  11.  
  12. >Today I was revising a program at work (OS2 REXX) and to my
  13. >surprise I could not find a way to do date arithmetic. I found
  14. >the date("base") which returs a julian date, but I could not
  15. >find anything that takes that format back into any other format.
  16. >
  17. >
  18. >Did I mean something?
  19.  
  20. No, you didn't miss anything.  REXX level 4 (the one implemented on
  21. most platforms) does not require any date conversion routines.  All it
  22. requires is that the Date() function return the current date in a
  23. variety of formats.
  24.  
  25. >                      I would think that date arithmetic should
  26. >be something that one would want as part of the standard REXX.
  27.  
  28. The ANSI REXX Committee agreed with you.  ANSI-standard REXX adds
  29. arguments to the Date() function for specifying a date to be converted
  30. and the format in which it is represented.  With that, and using
  31. the Basedate format, you can do all the math you want.  Watch out if
  32. you interests lie before the 20th century, however, as the algorithm
  33. for calulating basedates doesn't take into account the widely varying
  34. dates for adoption of the Gregorian calendar.
  35.  
  36. Now, if only we had some ANSI-standard REXX implementations available!
  37. But I guess it's too early to be whining.
  38.  
  39. Ross Patterson
  40. Sterling Software, Inc.
  41. VM Software Division
  42.